package com.ship.dispatch.service.orderPay;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.github.pagehelper.PageInfo;
import com.ship.common.core.web.domain.JsonResult;
import com.ship.common.business.service.BaseService;
import com.ship.dispatch.bean.orderPay.SpFundManage;
import com.ship.dispatch.bean.orderPay.SpFundManageDetail;
import com.ship.dispatch.bo.orderPay.SpFundManageDetailBo;
import com.ship.dispatch.bo.orderPay.SpFundManageUpdateBo;

import java.math.BigDecimal;
import java.util.List;

public interface SpFundManageDetailService extends BaseService<SpFundManageDetail> {
    /**
     * 统计支付次数
     * @return
     */
    Integer getPayNumberTotal();

    /**
     * 统计账户余额
     * @return
     */
    BigDecimal getAccountBalanceTotal();
    /**
     * 船舶代理平均费用
     * @return
     */
    BigDecimal getShipAgencyAverageBalance();
    /**
     * 获取调度优化方案甘特图信息
     * @param corporateName
     * @return
     */
    JsonResult<SpFundManageDetail> baseStatistics(String corporateName);

    /**
     * 资金明细分页查询
     * @param dto
     * @return
     */
    JsonResult<SpFundManage> getPage(SpFundManage dto);

    /**
     * 资金明细状态批量更新
     * @param dto
     * @return
     */
    JsonResult batchUpdate(SpFundManageUpdateBo dto);

    /**
     * 账户余额变更
     * @param dto
     * @return
     */
    JsonResult balanceUpdate(SpFundManageUpdateBo dto);

    /**
     * 获取列表
     * @param dto
     * @return
     */
    List<SpFundManage> getList(SpFundManage dto);

    /**
     * 获取详情数量
     * @param corporateName
     * @return
     */
    Integer getOrderCountByCorporateName(String corporateName);

    PageInfo<SpFundManageDetail> getManageDetailPage(SpFundManageDetailBo dto);

    List<SpFundManageDetail> getExportManageDetail(SpFundManageDetailBo dto);
}
